package com.xtq.countclass.service.impl;

import com.xtq.countclass.entity.Record;
import com.xtq.countclass.dao.RecordDao;
import com.xtq.countclass.service.RecordService;
import org.springframework.stereotype.Service;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.PageImpl;
import org.springframework.data.domain.PageRequest;

import javax.annotation.Resource;
import java.util.List;

/**
 * (Record)表服务实现类
 *
 * @author makejava
 * @since 2024-03-11 22:43:19
 */
@Service("recordService")
public class RecordServiceImpl implements RecordService {
	@Resource
	private RecordDao recordDao;
	
	/**
	 * 通过ID查询单条数据
	 * @return 实例对象
	 */
	@Override
	public List<Record> queryAll() {
		return  this.recordDao.queryAll();
	}
	
	/**
	 * 分页查询
	 *
	 * @param record      筛选条件
	 * @param pageRequest 分页对象
	 * @return 查询结果
	 */

	/**
	 * 新增数据
	 *
	 * @param record 实例对象
	 * @return 实例对象
	 */
	@Override
	public Record insert(Record record) {
		this.recordDao.insert(record);
		return record;
	}
	

	

}
